home *** CD-ROM | disk | FTP | other *** search
- Path: rap.SanDiegoCA.ATTGIS.COM!es013!jbc
- From: jbc@ElSegundoCA.ATTGIS.COM (Jim Chapman)
- Newsgroups: comp.lang.c++
- Subject: Re: C++ questions
- Date: 11 Jan 1996 01:45:01 GMT
- Organization: AT&T Global Information Solutions
- Distribution: world
- Message-ID: <4d1q2t$kj7@rap.SanDiegoCA.ATTGIS.COM>
- References: <4d0um5$9jf@cisu2.jsc.nasa.gov>
- Reply-To: jbc@ElSegundoCA.ATTGIS.COM
- NNTP-Posting-Host: es013.elsegundoca.attgis.com
-
- In article 9jf@cisu2.jsc.nasa.gov, Norman LaFave <lafave@ial4.jsc.nasa.gov> () writes:
- > Hi all,
- >
- > I wanted to ask the gurus here some questions:
- >
- > 1.) How do you handle a variable number of arguements to a function
- > since the elipsis of C does not work.
- >
- Not true. Elipsis is valid in a C++ function prototype. It's less frequently
- used than in C because C++ supports default arguments.
-
- > 2.) Can an object be instantiated with a variable containing a value
- > instead of explicitely with a number.
- >
- For non-static objects, yes.
-
- > 3.) Can the type a template is instantiated with be queried (I am trying
- > to write an exception which limits the data types the template can be
- > instantiated with).
- >
- There are techniques for querying querying template parameter types.
-
- > 4.) How often have you found that composition is a better choice than
- > inheritance (I find myself using it 75% of the time).
- >
- Sounds about right.
-
- > 5.) Can C++ be made multithreaded.
- >
- You betcha. The issues are the same as with C.
-
- > 6.) Can C++ be made portable through some library calls for instance.
- >
- You can certainly write portable (or non-portable) C++ code. For code
- that must be ported immediately, stay away from features that are not
- as widely implemented yet (e.g. RTTI). To plan for portability long-
- term, keep an eye on the draft standard.
-
- > 7.) How many of you see Java as a real replacement for C++ (not just for
- > web applications, but for all applications.
- >
- Not me.
-
-
-
- ---
- ==== AT&T | Jim Chapman |
- =--=== Global | Multimedia Projects | jbc@ElSegundoCA.ATTGIS.COM
- =--=== Information | 100 N. Sepulveda Blvd. | Voice: (310) 524-6747
- ==== Solutions | El Segundo, CA 90245 | FAX: (310) 524-5515
-
-